from copy import deepcopy


source = [1, 2, 3, [4, 5, 6], 7]

copy = deepcopy(source)


print(id(source) == id(copy))
print(id(source[3]) == id(copy[3]))


source[3][0] = 'xxx'

print(copy)   # [1, 2, 3, [4, 5, 6], 7]
print(source)  # [1, 2, 3, ['xxx', 5, 6], 7]